package com.qf.feign;

import feign.RequestInterceptor;
import feign.RequestTemplate;
import org.springframework.stereotype.Component;

/**
 * @author MI
 * @ClassName CustomerRequestInterceptor.java
 * @createTime 2021年12月19日 14:53:00
 */
@Component
public class CustomerRequestInterceptor implements RequestInterceptor {

    @Override
    public void apply(RequestTemplate template) {
        //统一设置请求头
        template.header("source", "cloud-order");
    }
}
